package io.geekidea.boot.chargeback.service.impl;

import io.geekidea.boot.chargeback.dto.ChargeBackExcel;
import io.geekidea.boot.chargeback.entity.ChargeBack;
import io.geekidea.boot.chargeback.mapper.ChargeBackMapper;
import io.geekidea.boot.chargeback.query.ChargeBackQuery;
import io.geekidea.boot.chargeback.service.ChargeBackService;
import io.geekidea.boot.chargeback.vo.ChargeBackVo;
import io.geekidea.boot.framework.service.impl.BaseServiceImpl;
import io.geekidea.boot.inventorychange.query.StoreChangeQuery;
import io.geekidea.boot.otherstores.query.total;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.List;

@Slf4j
@Service
public class ChargeBackServiceImpl extends BaseServiceImpl<ChargeBackMapper, ChargeBack> implements ChargeBackService {

    @Resource
    private ChargeBackMapper chargeBackMapper;

    @Override
    public List<ChargeBack> chargeBackLick(ChargeBackQuery chargeBackQuery) throws Exception {
        return chargeBackMapper.chargeBackLick(chargeBackQuery);
    }

    @Override
    public total getTotal(ChargeBackQuery chargeBackQuery) throws Exception {
        return chargeBackMapper.getTotal(chargeBackQuery);
    }

    @Override
    public List<ChargeBackExcel> DownloadList(ChargeBackQuery chargeBackQuery) {
        return chargeBackMapper.DownloadList(chargeBackQuery);
    }

//    @Override
//    public boolean addChargeById(ChargeBack chargeBack) {
//        return chargeBackMapper.addChargeById(chargeBack) > 0;
//    }
}
